package cn.benben.app.controller;


import cn.benben.system.api.SysUserApi;
import cn.benben.system.api.dto.TestDTO;
import org.apache.dubbo.config.annotation.DubboReference;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("test")
public class TestController {


    @DubboReference()
    private SysUserApi sysUserApi;

    @GetMapping("{msg}")
    public String test(@PathVariable("msg") String msg){
        System.out.println("1111111111111111");
        TestDTO testDTO = new TestDTO();
        testDTO.setMsg(msg);
        String s = sysUserApi.queryUser(testDTO);
        return s;
    }

}
